/*
 * Copyright (C) 2004-2007  Autodesk, Inc.
 * 
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of version 2.1 of the GNU Lesser
 * General Public License as published by the Free Software Foundation.
 * 
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
*
*
*/

#include "stdafx.h"

#include "FDO\Providers\WCS\Override\mgObjectFactory.h"
//#include "FDO\Providers\WCS\Override\mgOvStyleDefinition.h"
#include "FDO\Providers\WCS\Override\mgOvCoverageCollection.h"
#include "FDO\Providers\WCS\Override\mgOvCoverageDefinition.h"
#include "FDO\Providers\WCS\Override\mgOvRasterDefinition.h"
#include "FDO\Providers\WCS\Override\mgOvClassDefinition.h"
#include "FDO\Providers\WCS\Override\mgOvClassCollection.h"

template <class fdoclas, class clas> 
inline NAMESPACE_OSGEO_RUNTIME::Disposable^ CHECK(FdoIDisposable* p, FdoBoolean autoDispose)
{
    return (dynamic_cast<fdoclas *>(p) ?  gcnew clas(IntPtr(p), autoDispose) : nullptr);
}

//NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvStyleDefinition^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvStyleDefinition(System::IntPtr ptr, System::Boolean autoDispose)
//{
//    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvStyleDefinition(ptr, autoDispose);
//}

NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvCoverageCollection^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvCoverageCollection(System::IntPtr ptr, System::Boolean autoDispose)
{
    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvCoverageCollection(ptr, autoDispose);
}

NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvCoverageDefinition^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvCoverageDefinition(System::IntPtr ptr, System::Boolean autoDispose)
{
    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvCoverageDefinition(ptr, autoDispose);
}

NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvRasterDefinition^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvRasterDefinition(System::IntPtr ptr, System::Boolean autoDispose)
{
    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvRasterDefinition(ptr, autoDispose);
}

NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvClassDefinition^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvClassDefinition(System::IntPtr ptr, System::Boolean autoDispose)
{
    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvClassDefinition(ptr, autoDispose);
}

NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvClassCollection^ NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::ObjectFactory::CreateOvClassCollection(System::IntPtr ptr, System::Boolean autoDispose)
{
    return gcnew NAMESPACE_OSGEO_FDO_PROVIDERS_WCS_OVERRIDE::OvClassCollection(ptr, autoDispose);
}
